CFLAGS	:= -ffast-math -msse -mfpmath=sse,387 -Wall -O2 -flto \
	-fomit-frame-pointer
LIBS	:= -lallegro -lmsdl -lfl
OBJS	:= main.o msdl_import.o sphere.o triangle.o bsdfs.o math.o color.o \
	bih.o pwld.o

all: pathological

pathological: $(OBJS)
	$(CC) $(CFLAGS) -o $@ $(OBJS) $(LIBS)

$(OBJS): %.o: %.c pathological.h Makefile
	$(CC) -c $(CFLAGS) -o $@ $<

clean:
	rm *.o pathological

